SELECT m.* from(
SELECT EBELN,EBELP,ZTITLE,NAME1,BUTXT,
(select  A.ID from ORG_MEMBER A where A.EXT_ATTR_2=P.ZEMAIL and rownum<2 and IS_DELETED = 0 and IS_ENABLE = 1) AS ZEMAIL,
(select  A.ID from ORG_MEMBER A where A.EXT_ATTR_2=P.ZEMAIL1 and rownum<2 and IS_DELETED = 0 and IS_ENABLE = 1)  AS ZEMAIL1,
(select  A.ID from ORG_MEMBER A where A.EXT_ATTR_2=P.ZEMAIL2 and rownum<2 and IS_DELETED = 0 and IS_ENABLE = 1) AS ZEMAIL2 ,
(select B.name from ORG_UNIT B,ORG_MEMBER A WHERE rownum=1 AND A.ORG_DEPARTMENT_ID = B."ID" and A.EXT_ATTR_2=P.ZEMAIL) DEPT,
(select  A.EXT_ATTR_1 from ORG_MEMBER A where A.EXT_ATTR_2=P.ZEMAIL2 and rownum<2 and IS_DELETED = 0 and IS_ENABLE = 1 )  AS PHONE,
(select  D.LOGIN_NAME from ORG_PRINCIPAL D, ORG_MEMBER A where rownum=1 AND A.ID=D.MEMBER_ID and A.EXT_ATTR_2=P.ZEMAIL AND D.IS_ENABLE='1') AS LOGINNAME,
(select  P.ID from ORG_POST P, ORG_MEMBER A where rownum=1 AND A.ORG_POST_ID=P.ID and A.EXT_ATTR_2=P.ZEMAIL AND A.IS_ENABLE='1') AS ZHIWEI,
BEDAT,EINDT,IFFLG,P.STATUS
FROM PURCHASE P
WHERE P.EBELP=10)m 
WHERE m.LOGINNAME IS NOT NULL AND m.ZEMAIL1 IS NOT NULL
ORDER BY EBELN DESC